package com.kaizzi.data.jdl.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.kaizzi.data.common.been.TempBeen;
import com.kaizzi.data.common.been.UserDetailBeen;
import com.kaizzi.data.jdl.entity.CrmMember;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author Kzen
 * @Description crm_member表
 * @date 2020/9/10
 */
public interface CrmMemberMapper extends BaseMapper<CrmMember> {
    Long getUserCount(@Param("startDate") String startDate, @Param("endDate") String endDate, @Param("utc")String utc);

    Long getKing(@Param("startDate") String startDate, @Param("endDate") String endDate);

    Long getWes(@Param("startDate") String startDate, @Param("endDate") String endDate);

    Long getTeamCount(@Param("startDate") String startDate, @Param("endDate") String endDate);

    List<TempBeen> getAgeDistribute(@Param("startDate") String startDate, @Param("endDate") String endDate);

    List<TempBeen> getGenderDistribute(@Param("startDate") String startDate, @Param("endDate") String endDate);
    List<TempBeen> getAreaDistribute(@Param("startDate") String startDate, @Param("endDate") String endDate);
    List<TempBeen> getVip(@Param("startDate") String startDate, @Param("endDate") String endDate);

    Long getRegistUser(@Param("startDate") String startDate, @Param("endDate") String endDate);

    Long getOldUser(@Param("startDate") String startDate, @Param("endDate") String endDate);

    List<TempBeen> getUtcGender(@Param("startDate") String startDate, @Param("endDate") String endDate);
    List<TempBeen> getUtcAge(@Param("startDate") String startDate, @Param("endDate") String endDate);
    List<TempBeen> getUtcArea(@Param("startDate") String startDate, @Param("endDate") String endDate);

    Long getTeamUser(@Param("startDate") String startDate, @Param("endDate") String endDate);
    Long getTeamNewUser(@Param("startDate") String startDate, @Param("endDate") String endDate);

    List<TempBeen> getLastSportTypeCount(@Param("startDate") String startDate, @Param("endDate") String endDate);
    List<TempBeen> getLastSportStatusCount(@Param("startDate") String startDate, @Param("endDate") String endDate);
    List<TempBeen> getTeamDemand(@Param("startDate") String startDate, @Param("endDate") String endDate);

    List<UserDetailBeen> getCrmUserDetail(@Param("mopenId") String mopenId);

    long getRegistUser2(@Param("startDate") String startDate, @Param("endDate") String endDate);
    long getOldUser2(@Param("startDate") String startDate, @Param("endDate") String endDate);
    long getTeamNewUser2(@Param("startDate") String startDate, @Param("endDate") String endDate);
    long getTeamOldUser2(@Param("startDate") String startDate, @Param("endDate") String endDate);

    List<TempBeen> getClubUser(@Param("startDate") String startDate, @Param("endDate") String endDate);


    //--------------------分割线--------------------

    List<CrmMember> findAll();

}
